﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Languages.aspx.cs" Inherits="WebService.Admin.Languages" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>Languages Page - GPS Travel</title>
    <style type="text/css">
        .style1
        {
            width: 583px;
        }
        .style2
        {
            width: 310px;
        }
    </style>
</head>
<body>
    <form id="form1" runat="server">
    <div>
    
        <table style="width:100%;">
            <tr>
                <td class="style2">
                    &nbsp;</td>
                <td class="style1">
                    &nbsp;</td>
                <td>
                    &nbsp;</td>
            </tr>
            <tr>
                <td class="style2">
                    &nbsp;</td>
                <td style="font-weight: 700" class="style1">
                    Category List 
                    | Go to
                    <asp:HyperLink ID="HyperLink3" runat="server" NavigateUrl="~/Admin/Item.aspx" 
                        style="text-align: right">Item List Page</asp:HyperLink>
                    &nbsp;
| Go to
                    <asp:HyperLink ID="HyperLink9" runat="server" NavigateUrl="~/Admin/Category.aspx" 
                        style="text-align: right">Category Page</asp:HyperLink>

&nbsp;
| Go to
                    <asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl="~/Admin/ListPlaces.aspx" 
                        style="text-align: right">ListPlaces Page</asp:HyperLink>
&nbsp;| Go to
                    <asp:HyperLink ID="HyperLink5" runat="server" 
                        NavigateUrl="~/Admin/DeviceItem.aspx" style="text-align: right">Device List Page </asp:HyperLink>
&nbsp;| Go to
                    <asp:HyperLink ID="HyperLink2" runat="server" 
                        NavigateUrl="~/Admin/DeviceHistory.aspx" style="text-align: right">DeviceHistory Page</asp:HyperLink>
&nbsp;| Go to
                    <asp:HyperLink ID="HyperLink6" runat="server" 
                        NavigateUrl="~/Admin/ItemsMultilang.aspx" style="text-align: right">Item List Multilang Page </asp:HyperLink>
&nbsp;| Go to
                    <asp:HyperLink ID="HyperLink7" runat="server" 
                        NavigateUrl="~/Admin/CategoryMultilang.aspx" style="text-align: right">Category Multilang Page</asp:HyperLink>

                    | Return
                    <asp:HyperLink ID="HyperLink4" runat="server" 
                        NavigateUrl="~/Admin/Default.aspx" style="text-align: right">Admin Page</asp:HyperLink>
                </td>
                <td>
                    &nbsp;</td>
            </tr>
            <tr>
                <td class="style2">
                    &nbsp;</td>
                <td class="style1">
                    <asp:ListView ID="ListView1" runat="server" DataSourceID="SqlDataSource1" 
            onsorting="ListView1_Sorting"  InsertItemPosition="LastItem" 
            onitemcommand="ListView1_ItemCommand" >
            <LayoutTemplate>
                <table border="0" cellpadding="1">
                    <tr style="background-color:#E5E5FE">
                        <th align="left" style="width:200px"><asp:LinkButton ID="lnkLanguage" runat="server" CommandName="Sort" CommandArgument="Language">Language</asp:LinkButton></th>
                        <th align="left" style="width:200px"><asp:LinkButton ID="lnkLangName" runat="server" CommandName="Sort" CommandArgument="Language">Language Name</asp:LinkButton></th>
                        <th></th>
                    </tr>
                    <tr id="itemPlaceholder" runat="server"></tr>
                </table>
                <asp:DataPager ID="ItemDataPager" runat="server" PageSize="20">
                    <Fields>
                        <asp:NumericPagerField ButtonCount="10" />
                    </Fields>
                </asp:DataPager>    
            </LayoutTemplate>
            <ItemTemplate>
                    <tr>
                        <td><asp:Label runat="server" ID="lblLanguage"><%#Eval("Language")%></asp:Label></td>
                        <td><asp:Label runat="server" ID="lblLangName"><%#Eval("LangName")%></asp:Label></td>
                        <td><asp:LinkButton ID="lnkEdit" runat="server" CommandName="Edit">Edit</asp:LinkButton></td>
                    </tr>
            </ItemTemplate>
            <AlternatingItemTemplate>
                    <tr style="background-color:#EFEFEF">
                        <td><asp:Label runat="server" ID="lblLanguage"><%#Eval("Language")%></asp:Label></td>
                        <td><asp:Label runat="server" ID="lblLangName"><%#Eval("LangName")%></asp:Label></td>
                        <td><asp:LinkButton ID="lnkEdit" runat="server" CommandName="Edit">Edit</asp:LinkButton></td>
                    </tr>
            </AlternatingItemTemplate>
            <EditItemTemplate>
                    <td>
                        <asp:TextBox ID="txtUpLanguage" runat="server" Text='<%#Eval("Language") %>' Width="200px"></asp:TextBox>
                    </td>
                    <td>
                        <asp:TextBox ID="txtUpLangName" runat="server" Text='<%#Eval("LangName") %>' Width="200px"></asp:TextBox>
                    </td>
                     <td>   
                            <asp:LinkButton ID="lnkUpdate" runat="server" CommandName="Update">Update</asp:LinkButton>
                            <asp:LinkButton ID="lnkDelete" runat="server" CommandName="Delete">Delete</asp:LinkButton>
                            <asp:LinkButton ID="lnkCancel" runat="server" CommandName="Cancel">Cancel</asp:LinkButton>
                    </td>
                    
                </tr>
            </EditItemTemplate>
            <InsertItemTemplate>
                <tr id="Tr1" runat="server">
                    <td>
                        <asp:TextBox ID="txtLanguage" runat="server" Text='<%#Eval("Language") %>' Width="200px">Language</asp:TextBox>
                    </td>
                    <td>
                        <asp:TextBox ID="txtLangName" runat="server" Text='<%#Eval("LangName") %>' Width="200px">LangName</asp:TextBox>
                    </td>
                     <td><asp:Button ID="InsertButton" runat="server" CommandName="Insert" Text="Insert" /></td>
                    
                </tr>
            </InsertItemTemplate>
            
        </asp:ListView>
        <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
            ConnectionString="<%$ ConnectionStrings:GPSTravelConnect %>" 
            SelectCommand="SELECT * FROM [tbl_Languages]" >
        </asp:SqlDataSource>
                </td>
                <td>
                    &nbsp;</td>
            </tr>
            <tr>
                <td class="style2">
                    &nbsp;</td>
                <td class="style1">
                    &nbsp;</td>
                <td>
                    &nbsp;</td>
            </tr>
        </table>
    
    </div>
    </form>
</body>
</html>
